package com.zhipu.balance.remotedata.systemapi;

import com.zhipu.balance.mobile.ResultEntity;
import com.zhipu.balance.mobile.event.RecordCorn;
import com.zhipu.balance.mobile.event.RecordDaMi;
import com.zhipu.balance.mobile.event.RecordRapeseed;
import com.zhipu.balance.mobile.event.RecordRice;
import com.zhipu.balance.mobile.event.RecordSoybean;
import com.zhipu.balance.mobile.event.RecordWheat;
import com.zhipu.balance.mobile.temporaryClass.Activate;
import com.zhipu.balance.mobile.temporaryClass.DevCode;
import com.zhipu.balance.mobile.temporaryClass.VersionUpdate;

import io.reactivex.Observable;
import retrofit2.http.Body;
import retrofit2.http.GET;
import retrofit2.http.Header;
import retrofit2.http.Headers;
import retrofit2.http.POST;

public interface SystemApiService {


    /**
     * 激活 （安卓屏调用）
     * @param Sign
     * @param Time
     * @param activate
     * @return
     */
    @POST("/g1/ibs/activate")
    Observable<ResultEntity<String>> activate(@Header("Sign") String Sign, @Header("Time") long Time, @Body Activate activate);

    /**
     * 更新软件
     * @return
     */
    @Headers({"Content-Type: application/json;charset=utf-8"})
    @GET("g1/apkst/balance/version2")
    Observable<VersionUpdate> version();

    /**
     * 获取设备序列号
     * @param Sign
     * @param Time
     * @param devCode
     * @return
     */
    @POST("/g1/h/blhi/getDeviceCode")
    Observable<ResultEntity<String>> DeviceCode(@Header("Sign") String Sign, @Header("Time") long Time, @Body DevCode devCode);


    /**
     * 上传天平数据- 稻谷
     * @param Sign
     * @param Time
     * @param mRecordRice
     * @return
     */
    @POST("g1/h/blhi/uploadRiceBalanceInfo")
    Observable<ResultEntity<String>> uploadRiceBalanceInfo(@Header("Sign") String Sign, @Header("Time") long Time, @Body RecordRice mRecordRice);



    /**
     * 上传天平数据- 小麦
     * @param Sign
     * @param Time
     * @param mRecordWheat
     * @return
     */
    @POST("g1/h/blhi/uploadWheatBalanceInfo")
    Observable<ResultEntity<String>> uploadWheatBalanceInfo(@Header("Sign") String Sign, @Header("Time") long Time, @Body RecordWheat mRecordWheat);


    /**
     * 上传天平数据- 玉米
     * @param Sign
     * @param Time
     * @param mRecordCorn
     * @return
     */
    @POST("g1/h/blhi/uploadCornBalanceInfo")
    Observable<ResultEntity<String>> uploadCornBalanceInfo(@Header("Sign") String Sign, @Header("Time") long Time, @Body RecordCorn mRecordCorn);


    /**
     * 上传天平数据- 大米
     * @param Sign
     * @param Time
     * @param mRecordDaMi
     * @return
     */
    @POST("g1/h/blhi/uploadTrueRiceBalanceInfo")
    Observable<ResultEntity<String>> uploadTrueRiceBalanceInfo(@Header("Sign") String Sign, @Header("Time") long Time, @Body RecordDaMi mRecordDaMi);


    /**
     * 上传天平数据- 大豆
     * @param Sign
     * @param Time
     * @param mRecordSoybean
     * @return
     */
    @POST("g1/h/blhi/uploadSoybeanBalanceInfo")
    Observable<ResultEntity<String>> uploadSoybeanBalanceInfo(@Header("Sign") String Sign, @Header("Time") long Time, @Body RecordSoybean mRecordSoybean);


    /**
     * 上传天平数据- 油菜籽
     * @param Sign
     * @param Time
     * @param mRecordRapeseed
     * @return
     */
    @POST("g1/h/blhi/uploadRapeseedBalanceInfo")
    Observable<ResultEntity<String>> uploadRapeseedBalanceInfo(@Header("Sign") String Sign, @Header("Time") long Time, @Body RecordRapeseed mRecordRapeseed);
}
